#!coding=utf-8
import xadmin
from .models import *
from xadmin.views.base import CommAdminView

class DayWeatherAdmin(object):
    list_display = ('name','low','height','wind','rain','date_str','source','province','city')
    search_fields = ('name','source','province','city')
    list_filter = ('date','source','province','city')
xadmin.site.register(DayWeather, DayWeatherAdmin)

class CityErrorAdmin(object):
    list_display = ('province','city','info')
    search_fields = ('province','city','info')
    list_filter = ('province','city')
xadmin.site.register(CityError, CityErrorAdmin)